package com.woniuxy.woniuhis.controller;

import com.woniuxy.woniuhis.entity.Medicine;
import com.woniuxy.woniuhis.mapper.MedicineMapper;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

/**
 * 药物的测试控制器
 */
@Controller

public class MediTestController {
    @Autowired
    private MedicineMapper medicineMapper;

    @RequestMapping("/mediList")
    @ResponseBody
    public List<Medicine> getMediList() {
        return medicineMapper.selectAllMedicine();
    }
}
